<?php defined('IN_ADMIN') or exit('Access Denied!'); ?>

<form id="myform" action="/admin/dish_cat/save/<?=$shop_id;?>" method="post">
  <input type="hidden" name="method" value="<?=$method;?>" />
  <div class="pad-10">
    <div class="col-tab">
      <ul class="tabBut cu-li">
        <li class="on">添加分类</li>
      </ul>
      <div class="content pad-10">
        <table width="100%" class="table_form">
          <tr>
            <td width="80">分类名称</td>
            <td><input type="text" class="input-text" name="cat_name" id="cat_name" value="" /></td>
          </tr>
        </table>
      </div>
    </div>
    <div class="bk15"></div>
    <input type="submit" class="button" id="dosubmit" name="dosubmit" value="提交" />
  </div>
</form>
<script type="text/javascript">
$(document).ready(function(){
    $.formValidator.initConfig({formid:"myform",autotip:true,onerror:function(msg,obj){window.top.art.dialog({content:msg,lock:true,width:'200',height:'50'}, function(){this.close();$(obj).focus();})}});
    $("#cat_name").formValidator({onshow:"请输入分类名称",onfocus:"请输入分类名称"}).inputValidator({min:1,onerror:"分类名称没有填写"});
});
</script>